import request from '@/utils/request'

export function fetchArticleList(data) {
  return request({
    url: '/cloud-system/getArticleList',
    method: 'post',
    data
  })
}

export function fetchArticleOne(data) {
  return request({
    url: '/cloud-system/getOneArticleDetail',
    method: 'post',
    data
  })
}

export function createArticle(data) {
  return request({
    url: '/cloud-system/createOneArticle',
    method: 'post',
    data
  })
}

export function updateArticle(data) {
  return request({
    url: '/cloud-system/updateOneArticle',
    method: 'post',
    data
  })
}

export function deleteArticle(data) {
  return request({
    url: '/cloud-system/deleteOneArticle',
    method: 'post',
    data
  })
}

export function lockArticle(data) {
  return request({
    url: '/cloud-system/lockOneArticle',
    method: 'post',
    data
  })
}

export function unlockArticle(data) {
  return request({
    url: '/cloud-system/unlockOneArticle',
    method: 'post',
    data
  })
}

export function getOneArticle(data) {
  return request({
    url: '/cloud-system/getOneArticle',
    method: 'post',
    data
  })
}
